home *** CD-ROM | disk | FTP | other *** search
/ Libris Britannia 4 / science library(b).zip / science library(b) / ELECTRON / 2687.ZIP / LS1.DOC < prev    next >
Text File  |  1990-07-27  |  27KB  |  683 lines

  1. 1.   LSYSTEM - Overview
  2.  
  3. The LSYSTEM digital logic simulation software package is  a  CAD  tool  which 
  4. allows users to (1) describe the  composition  and  structure  of  a  digital 
  5. system comprising combinational logic elements, sequential logic elements and 
  6. memory devices, (2) verify the system's logic function, and (3) simulate  and 
  7. display the timing diagram  for  specified  logic  signals.   LSYSTEM  allows 
  8. complete flexibility in  the  use  and  generation  of  logic  element  model 
  9. libraries.   Logic elements can be modelled as gate level primitives or at  a 
  10. higher functional level.   Gate and functional level  models  can  be  freely 
  11. mixed in both the model libraries and logic network simulations.
  12.  
  13. - Logic networks are described in a form similar to SPICE.
  14. - Node names can be alphanumeric up to 16 characters long.
  15. - 10k Maximum nodes.
  16. - Maximum logic elements is dependent on system memory.
  17. - 500 maximum user defined gate and functional primitives.
  18. - 500 user defined macros.
  19. - 256 maximum internal states for sequential primitives.
  20. - Comprehensive default primitive library supplied.
  21. - Range of TTL and CMOS macros supplied.
  22. - Zero propagation delays allowed with gate and functional elements.
  23. - Resolution of 1nS during simulation.
  24. - Primitive element delays may be set from 0 to 4S.
  25. - Primitive element strengths can be set from 0 to 100%.
  26. - Macro nesting up to 20 levels deep.
  27. - Unlimited number of include files.
  28. - Include file nesting to 20 levels deep.
  29. - Full network description syntax checking.
  30. - Rigorous declaration checking for correct number of nodes etc..
  31. - Errors reported in a user friendly manner.
  32. - Fast and accurate simulation cycle.
  33. - Flexible digital waveform post-simulation graphics processor.
  34.  
  35.   PLEASE NOTE the LSYSTEM specification presented above referees to the
  36.   Production version of the software.  Files LS1.DOC, LS2.DOC and LS3.DOC
  37.   describe the production software - the SHAREWARE version of LSYSTEM is a
  38.   full working version of the package BUT is restricted in the size of logic
  39.   network it can simulate.  SEE file README.1 for the SHAREWARE details.
  40.  
  41. 2.   Specification of the computer system required to run LSYSTEM
  42.  
  43. Computer:                IBM PC/XT/AT family.
  44. Memory:                  640k ram required.
  45. Floppy disk:             at least two 5.25" DSDD 360k capacity.
  46. Hard disk:               optional.
  47. Numeric coprocessor:     not required.
  48. Printer:                 9 or 24 pin dot matrix.
  49. Operating system:        MS/PC DOS 2.0 upwards.
  50. Mouse:                   optional.
  51.  
  52.  
  53. Graphics adapters, one of the following or 100% clones:-
  54.  
  55.                          IBM Colour Graphics Adapter (CGA). 
  56.                          IBM Enhanced Graphics Adapter (EGA).
  57.                          IBM Video Graphics ARRAY (VGA).
  58.                          Hercules Monochrome Graphics Adapter.
  59.  
  60. 3.   Installing LSYSTEM
  61.  
  62. Ensure that the CONFIG.SYS file on your boot disk ( whether hard or floppy ) 
  63. contains the lines :-
  64.                          FILES     = 20
  65.                          BUFFERS   = 20
  66.  
  67. Copy all files from the set of LSYSTEM disks into your chosen directory.  The 
  68. LSYSTEM software is now ready to be used for digital  logic  simulation.   In 
  69. this publication it is  assumed  that  the  LSYSTEM  software  resides  in  a 
  70. directory called LSYSTEM on the C drive.    If  you  are  using  floppy  disk 
  71. drives see Appendix A for installation instructions.
  72.  
  73. 4.   Using LSYSTEM
  74.  
  75. 4.1  The Simulation cycle
  76.  
  77. Three programs are used to complete the simulation cycle:-
  78.  
  79.      (1) COMPILE.EXE, (2) SIMULATE.EXE and (3) WAVEFORM.EXE.
  80.  
  81. To simulate and study the performance of  a  digital  logic  network  over  a 
  82. specified time period, several steps are required, these are:-
  83.  
  84. - Describe the structure and logic elements which form the  digital  network,   
  85.   specify all input signals and output test points, in file FILE.NWK using a 
  86.   suitable NON-DOCUMENT text editor. 
  87. - Compile the network description using COMPILE.EXE.
  88. - Simulate the network using SIMULATE.EXE.
  89. - View the logic network signal waveforms using WAVEFORM.EXE.
  90. - Inspect tabular results in file FILE.RLT.
  91.  
  92. Various files are required (or  generated)  at each  stage,  they  are  as 
  93. follows, where FILE is the logic network name chosen:-
  94.  
  95. COMPILE.EXE        FILE.NWK --+   FILE.INF --   Information
  96.                   I   FILE.EXP --   Macro expansion    
  97.                               I   FILE.LST --+
  98.                               I   FILE.MOD   I- DATA files
  99.                               I   FILE.TRA   I
  100.                               I   FILE.NAM---+
  101.                               +---------------- Network description
  102.  
  103. SIMULATE.EXE       FILE.FNC --+
  104.                    FILE.MOD   I
  105.                    FILE.TRA   I
  106.                    FILE.NAM   I---------------- Data
  107.                               I
  108. WAVEFORM.EXE       FILE.GRA   I
  109.                    FILE.NAM --+
  110.  
  111.                    INPUT FILES    OUTPUT FILES
  112.  
  113. Fig. 1 outlines the complete simulation sequence and the relationship between 
  114. the input and output files.
  115.  
  116.        SEE PRINTED USER GUIDE FOR DIAGRAM
  117.  
  118. A minimum simulation cycle, assuming a digital network description  had  been 
  119. generated, using for example the PCWRITE word processor,  in  file  test.NWK, 
  120. would proceed as follows ( ignore  the  DOS  prompt,  this  is  included  for 
  121. completeness ):-
  122.  
  123.      C:\LSYSTEM> compile test <ENTER>
  124.  
  125.      - Correct any errors ( using a text editor or word processor ) and 
  126.        repeat.
  127.  
  128.      C:\LSYSTEM> simulate test <ENTER>
  129.  
  130.      - Inspect the "test.RLT" file of tabular output results.
  131.      - May stop the simulation cycle here if the tabular data is sufficient.
  132.  
  133.      C:\LSYSTEM> waveform test <ENTER>
  134.  
  135.      - Inspect graphical output of trace data.
  136.      - Make modifications to the network description file "test.NWK".
  137.      - Repeat simulation cycle from the compilation stage or finish.
  138.  
  139. 4.2  Compiler options
  140.  
  141. Once a network description file ( for example file.NWK )  has  been  created, 
  142. the compiler can be invoked from the DOS command line by entering:-
  143.  
  144.      C:\LSYSTEM> compile file[.NWK] [switches......] <ENTER>
  145.  
  146. where the switches and the file extension  ".NWK"  are  optional  parameters.   
  147. The currently available switches are:-
  148.  
  149.      -l Generate a listing file, reporting any errors, (output file.LST).
  150.      -e Generate an expanded file, macros fully expanded, (output file.EXP)
  151.      -h Display a help screen, output highlights basic syntax rules.
  152.  
  153. Entering
  154.  
  155.      C:\LSYSTEM> compile <ENTER>
  156.  
  157. alone, will display the basic invocation instructions on the screen.
  158.  
  159. 4.3  Simulator options
  160.  
  161. Once the digital network description file has been compiled, and found to  be 
  162. error free, the simulator is invoked from the DOS command line by entering:-
  163.  
  164.      C:\LSYSTEM> simulate file <ENTER>
  165.  
  166. No command line switches are available.
  167.  
  168. 4.4  Waveform options
  169.  
  170. After simulation, the digital network simulation  results  can  be  displayed 
  171. graphically from the DOS command line by entering:-
  172.  
  173.      C:\LSYSTEM> waveform file [switches......] <ENTER>
  174.  
  175. where  the  switches  are  optional  parameters.    All   graphical   display 
  176. parameters,  such  as  window  sizing,  are  calculated,  from  automatically 
  177. detected graphics adapter information, if no switches are used to  specify  a 
  178. given display adapter.     The  waveform program also assumes that a mouse  ( 
  179. Microsoft mouse or a 100%  compatible  clone  )  is  not  installed  on  your 
  180. computer system.   The available switches are:-
  181.  
  182.      -CGA_BL   Set graphics to CGA 320 x 200 black and white mode.
  183.      -CGA_C    Set graphics to CGA 320 x 200 colour mode.
  184.      -CGA_BH   Set graphics to CGA 640 x 200 black and white mode.
  185.      -EGA_C    Set graphics to EGA 640 x 350 colour mode.
  186.      -EGA_B    Set graphics to EGA 640 x 350 black and white mode.
  187.      -VGA_C    Set graphics to VGA 640 x 480 colour mode.
  188.      -VGA_B    Set graphics to VGA 640 x 480 black and white mode.
  189.      -HERC     Set graphics to Hercules  black and white mode.
  190.  
  191.      -MOUSE    Activate MOUSE.  Must only be used if a MOUSE driver is
  192.                installed.
  193.  
  194. Note all the graphics mode change switches can be interactively operated from 
  195. the keyboard when the waveform graphics post processor program is running.
  196.  
  197. 4.5  LSYSTEM batch files LS.BAT and LSM.BAT
  198.  
  199. Two batch files are provided on the LSYSTEM master disks.  These batch  files 
  200. automate the simulation cycle.  Batch file LS.BAT assumes that your  computer 
  201. does NOT have a mouse installed.  The reverse is true for batch file LSM.BAT.   
  202. The complete LSYSTEM cycle can be  invoked  from  the  DOS  command  line  by 
  203. entering:-
  204.  
  205.      C:\LSYSTEM> LS  file <ENTER>     or
  206.      C:\LSYSTEM> LSM file <ENTER>     if you have a mouse installed.
  207.  
  208. 5.   Creating a digital logic network description file
  209.  
  210. 5.1  The LSYSTEM logic network description language
  211.  
  212. The LSYSTEM logic network description  language  is  modelled  on  the  SPICE 
  213. language and has a similar format.   The minimum  information  needed  to  be 
  214. able to simulate the function and timing of a digital  system  is  a  set  of 
  215. statements which:-
  216.  
  217.      - Define the logic network topology
  218.      - Give the the logic element types and parameters
  219.      - Describe the primitive element models and MACRO structures
  220.      - Define the signals driving the logic system
  221.      - Specify what signals to monitor during the simulation
  222.      - Control the simulation task
  223.  
  224. Only one statement per line is allowed by LSYSTEM
  225.  
  226. The LAST statement in the logic network  description  file  must  be  a  .END 
  227. entry; NOTE NO space between the . and the E character.
  228.  
  229. Any statement that begins with a * is assumed by  LSYSTEM  to  be  a  COMMENT 
  230. statement.
  231.  
  232. Statements may be entered in either lower or upper case letters, and indeed a 
  233. mixture of both forms is  allowed,  but  please  note  LSYSTEM  converts  all 
  234. letters to upper case so names entered, for example, as GATE1, gate1 or GaTe1 
  235. are identical.
  236.  
  237. Logic element DELAY or RISE or FALL times  must  be  entered  as  an  INTEGER 
  238. number of nano seconds.
  239.  
  240. Logic element STRENGTH values or HIGH  or  LOW  values  must  be  entered  as 
  241. INTEGER percentages in the range 0% to 100%.
  242.  
  243. The logic network description is a nodal representation of the digital system 
  244. to be simulated.   Each connection point between elements, these  are  called 
  245. nodes, is allocated a unique name ( up to 16 characters long ).    The  total 
  246. network is described in terms of the functional logic elements, from which it 
  247. is built, and how these elements interconnect.   The  interconnecting  points 
  248. or nodes represent the functional elements input/output  pins,  for  example, 
  249. the following network has 4 nodes: A, B, C and D:-
  250.  
  251.            +-----+         +------+
  252.            I  &  I         I   1  I
  253.     A  ----I     I    C    I      I         
  254.            I     I---------I      I-------- D
  255.     B  ----I     I         I      I
  256.            I     I         I      I
  257.            +-----+         +------+
  258.  
  259. This network would be described by saying that the two  input  AND  gate  has 
  260. inputs A and B, with output C connected to the  input  of  the  buffer  gate.   
  261. The output of the buffer gate is D.
  262.  
  263. 5.2  An example simulation
  264.  
  265. At this stage in the description  of  the  LSYSTEM  CAD  package  an  example 
  266. simulation is introduced.   The example has been chosen to illustrate a range 
  267. of basic features provided by the software.
  268.  
  269. 5.2.1     A synchronous BCD mod 16 counter
  270.  
  271.     SEE PRINTED USER GUIDE FOR DIAGRAM
  272.  
  273. 5.2.2     The network description file - BCD16.NWK
  274.  
  275. * Example 1 --- SYNCHRONOUS BCD MOD 16 COUNTER
  276. *               This example illustrates the "FILE.NWK" structure
  277. *               and a range of basic features provided by the
  278. *               LSYSTEM CAD software. 
  279. *
  280. .LIB DEFAULT.LIB ; Load the SHAREWARE default logic primitive library.
  281. *
  282. GEN1 CLOCK  CLK0 PERIOD(500)  ; Periodic clock generator. 
  283. GEN2 PRESET CLK1              ; PRESET set to logic 1. 
  284. GEN3 CLEAR  CLK0 300          ; CLEAR changes from logic 0 to 1 at 300nS.
  285. GEN4 COUNT  CLK0 600          ; COUNT changes from logic 0 to 1 at 600nS.
  286. GEN5 J1K1   CLK1              ; J1K1 input set to logic 1. 
  287. *
  288. .macro jkff_cp_ne j clock k clear qn q preset ; JKFF negative edge triggered
  289.     g1  clock clockn INV (delay=3)            ; MACRO.
  290.     ic1 clockn clear preset j k q qn jkff_cp_pe
  291. .endm
  292. *
  293. G1 CLOCK COUNT CLK AND2 (DELAY=6)                 ; Start of logic network 
  294. IC1 J1K1 CLK J1K1 CLEAR QN1 Q1 PRESET jkff_cp_ne  ; description.
  295. G2  Q1 QN4 J2K2 AND2 (DELAY=6)
  296. IC2 J2K2 CLK J2K2 CLEAR QN2 Q2 PRESET jkff_cp_ne
  297. G3  J2K2 Q2 J3K3 AND2 (DELAY=6)
  298. IC3 J3K3 CLK J3K3 CLEAR QN3 Q3 PRESET jkff_cp_ne
  299. G4 J3K3 Q3 J4 AND2 (DELAY=6)
  300. IC4 J4 CLK Q1 CLEAR QN4 Q4 PRESET jkff_cp_ne
  301. *
  302. .TIME 6500 6500            ; Simulation duration. 
  303. *
  304. .PRINT PRESET CLEAR COUNT CLOCK Q1 Q2 Q3 Q4 J1K1 J2K2 J3K3 ; Trace node list
  305. *
  306. .END 
  307.  
  308. 5.2.3     File BCD16.LST
  309.  
  310. ***************************** LSYSTEM V2.0 ***************************
  311. Logic network listing for compilation of BCD16.NWK
  312. 0001: * Example 1 --- SYNCHRONOUS BCD MOD 16 COUNTER
  313. 0002: *               This example illustrates the "FILE.NWK" structure
  314. 0003: *               and a range of basic features provided by the
  315. 0004: *               LSYSTEM CAD software. 
  316. 0005: *
  317. 0006: .LIB DEFAULT.LIB;
  318. 0007: *
  319. 0008: GEN1 CLOCK  CLK0 PERIOD(500);
  320. 0009: GEN2 PRESET CLK1;
  321. 0010: GEN3 CLEAR  CLK0 300;
  322. 0011: GEN4 COUNT  CLK0 600;
  323. 0012: GEN5 J1K1   CLK1;
  324. 0013: *
  325. 0014: .macro jkff_cp_ne j clock k clear qn q preset;
  326. 0015:     g1  clock clockn INV (delay=3);
  327. 0016:     ic1 clockn clear preset j k q qn jkff_cp_pe
  328. 0017: .endm
  329. 0018: *
  330. 0019: G1 CLOCK COUNT CLK AND2 (DELAY=6);
  331. 0020: IC1 J1K1 CLK J1K1 CLEAR QN1 Q1 PRESET jkff_cp_ne;
  332. 0021: G2  Q1 QN4 J2K2 AND2 (DELAY=6)
  333. 0022: IC2 J2K2 CLK J2K2 CLEAR QN2 Q2 PRESET jkff_cp_ne
  334. 0023: G3  J2K2 Q2 J3K3 AND2 (DELAY=6)
  335. 0024: IC3 J3K3 CLK J3K3 CLEAR QN3 Q3 PRESET jkff_cp_ne
  336. 0025: G4 J3K3 Q3 J4 AND2 (DELAY=6)
  337. 0026: IC4 J4 CLK Q1 CLEAR QN4 Q4 PRESET jkff_cp_ne
  338. 0027: *
  339. 0028: .TIME 6500 6500;
  340. 0029: *
  341. 0030: .PRINT PRESET CLEAR COUNT CLOCK Q1 Q2 Q3 Q4 J1K1 J2K2 J3K3;
  342. 0031: *
  343. 0032: .END 
  344. ***** NODE and MACRO related warnings ***** 
  345.  
  346. 5.2.4     File BCD16.EXP
  347.  
  348. ***************************** LSYSTEM V2.0 ***************************
  349. * Expansion listing for compilation of BCD16.NWK
  350. .LIB DEFAULT.LIB;
  351. GEN1 CLOCK  CLK0 PERIOD(500);
  352. GEN2 PRESET CLK1;
  353. GEN3 CLEAR  CLK0 300;
  354. GEN4 COUNT  CLK0 600;
  355. GEN5 J1K1   CLK1;
  356. *-------------------- .macro jkff_cp_ne j clock k clear qn q preset;
  357. *--------------------     g1  clock clockn INV (delay=3);
  358. *--------------------     ic1 clockn clear preset j k q qn jkff_cp_pe
  359. *-------------------- .endm
  360. G1 CLOCK COUNT CLK AND2 (DELAY=6);
  361. *IC1 J1K1 CLK J1K1 CLEAR QN1 Q1 PRESET jkff_cp_ne;
  362.    G1_0  CLK $1_CLOCKN INV DELAY 3 
  363.    IC1_1  $1_CLOCKN CLEAR PRESET J1K1 J1K1 Q1 QN1 JKFF_CP_PE 
  364. G2  Q1 QN4 J2K2 AND2 (DELAY=6)
  365. *IC2 J2K2 CLK J2K2 CLEAR QN2 Q2 PRESET jkff_cp_ne
  366.    G1_2  CLK $2_CLOCKN INV DELAY 3 
  367.    IC1_3  $2_CLOCKN CLEAR PRESET J2K2 J2K2 Q2 QN2 JKFF_CP_PE 
  368. G3  J2K2 Q2 J3K3 AND2 (DELAY=6)
  369. *IC3 J3K3 CLK J3K3 CLEAR QN3 Q3 PRESET jkff_cp_ne
  370.    G1_4  CLK $3_CLOCKN INV DELAY 3 
  371.    IC1_5  $3_CLOCKN CLEAR PRESET J3K3 J3K3 Q3 QN3 JKFF_CP_PE 
  372. G4 J3K3 Q3 J4 AND2 (DELAY=6)
  373. *IC4 J4 CLK Q1 CLEAR QN4 Q4 PRESET jkff_cp_ne
  374.    G1_6  CLK $4_CLOCKN INV DELAY 3 
  375.    IC1_7  $4_CLOCKN CLEAR PRESET J4 Q1 Q4 QN4 JKFF_CP_PE 
  376. .TIME 6500 6500;
  377. .PRINT PRESET CLEAR COUNT CLOCK Q1 Q2 Q3 Q4 J1K1 J2K2 J3K3;
  378. .END 
  379.  
  380. 5.2.5     File BCD16.INF
  381.  
  382. ***************************** LSYSTEM V2.0 ***************************
  383.  
  384.  
  385. Information file for network BCD16.NWK
  386.  
  387.  Number of source lines compiled:                  32
  388.  Number of nodes in network:                       21
  389.  Number of trace nodes:                            11
  390.  Number of logic components in network:            12
  391.  Number of excitation clocks:                       5
  392.  Simulation length:                              6500
  393.  Simulation display period:                      6500
  394.  Number of primitives loaded:                      63
  395.  Number of macros loaded:                           1
  396.  Number of used macros:                             1
  397.  Highest macro nesting:                             1
  398.  
  399. --- S Y M B O L    T A B L E ---
  400.  
  401. {0001} $1_CLOCKN                        {0002} $2_CLOCKN                   
  402. {0003} $3_CLOCKN                        {0004} $4_CLOCKN                     
  403. {0005} CLEAR                            {0006} CLK                           
  404. {0007} CLOCK                            {0008} COUNT                         
  405. {0009} J1K1                             {0010} J2K2                          
  406. {0011} J3K3                             {0012} J4                            
  407. {0013} PRESET                           {0014} Q1                            
  408. {0015} Q2                               {0016} Q3                            
  409. {0017} Q4                               {0018} QN1                           
  410. {0019} QN2                              {0020} QN3                           
  411. {0021} QN4                                 
  412.  
  413. --- U S E D   P R I M I T I V E   T A B L E ---
  414.  
  415. 0004 off AND2
  416. 0004 off INV
  417. 0004 off JKFF_CP_PE
  418.  
  419. --- U S E D   M A C R O   T A B L E ---
  420.  
  421. {0000} JKFF_CP_NE
  422.  
  423. 5.2.6     Tabular results - file BCD16.RLT
  424.  
  425. ******************************* LSYSTEM V 2.0 ******************************
  426. Simulation Results for network file BCD16.FNC
  427.  
  428.                   PCCCQQQQJJJ
  429.                   RLOL1234123
  430.                   EEUO    KKK
  431.                   SANC    123
  432.                   ERTK       
  433.   Time..... (nS)  T          
  434.                              
  435.  
  436.   Startup condition 
  437.  
  438.           0:      0111XXXX0XX
  439. NC        1:      1000XXXX1XX
  440. NC        2:      1000XXXX1XX
  441. NC        3:      1000XXXX1XX
  442. NC        4:      1000XXXX1XX
  443. NC        5:      1000XXXX1XX
  444. NC        6:      1000XXXX1XX
  445. NC        7:      1000XXXX1XX
  446. NC        8:      1000XXXX1XX
  447. NC        9:      1000XXXX1XX
  448. NC       10:      1000XXXX1XX
  449. NC       11:      1000XXXX1XX
  450. NC       12:      1000XXXX1XX
  451. NC       13:      1000XXXX1XX
  452. NC       14:      1000XXXX1XX
  453. NC       15:      1000XXXX11X
  454. NC       16:      1000XXXX11X
  455. NC       17:      1000XXXX11X
  456. NC       18:      1000XXXX11X
  457. NC       19:      1000XXXX11X
  458. NC       20:      1000XXXX11X
  459. NC       21:      1000XXXX111
  460. NC       22:      1000XXXX111
  461. NC       23:      1000XXXX111
  462. NC       24:      10000000111
  463. NC       30:      10000000100
  464. NC      250:      10010000100
  465. NC      300:      11010000100
  466. NC      500:      11000000100
  467. NC      600:      11100000100
  468. NC      750:      11110000100
  469. NC     1000:      11100000100
  470. NC     1018:      11101000100
  471. NC     1024:      11101000110
  472. NC     1250:      11111000110
  473. NC     1500:      11101000110
  474. NC     1518:      11101100110
  475. NC     1524:      11100100111
  476. NC     1530:      11100100101
  477. NC     1536:      11100100100
  478. NC     1750:      11110100100
  479. NC     2000:      11100100100
  480. NC     2018:      11101100100
  481. NC     2024:      11101100110
  482. NC     2030:      11101100111
  483. NC     2250:      11111100111
  484. NC     2500:      11101100111
  485. NC     2518:      11101110111
  486. NC     2524:      11100010111
  487. NC     2530:      11100010100
  488. NC     2750:      11110010100
  489. NC     3000:      11100010100
  490. NC     3018:      11101010100
  491. NC     3024:      11101010110
  492. NC     3250:      11111010110
  493. NC     3500:      11101010110
  494. NC     3518:      11101110110
  495. NC     3524:      11100110111
  496. NC     3530:      11100110101
  497. NC     3536:      11100110100
  498. NC     3750:      11110110100
  499. NC     4000:      11100110100
  500. NC     4018:      11101110100
  501. NC     4024:      11101110110
  502. NC     4030:      11101110111
  503. NC     4250:      11111110111
  504. NC     4500:      11101110111
  505. NC     4518:      11101111111
  506. NC     4524:      11100001111
  507. NC     4530:      11100001100
  508. NC     4750:      11110001100
  509. NC     5000:      11100001100
  510. NC     5018:      11101001100
  511. NC     5250:      11111001100
  512. NC     5500:      11101001100
  513. NC     5524:      11100000110
  514. NC     5530:      11100000100
  515. NC     5750:      11110000100
  516. NC     6000:      11100000100
  517. NC     6018:      11101000100
  518. NC     6024:      11101000110
  519. NC     6250:      11111000110
  520.        6500:      11101000110
  521.  
  522. 5.2.7     A screen dump of the BCD16 Network timing diagram
  523.  
  524.           SEE PRINTED USER GUIDE FOR DIAGRAM
  525.  
  526. 5.3  The structure of the LSYSTEM network description file
  527.  
  528. The  following  template  outlines  the  structure  of  the  LSYSTEM  network 
  529. description file:-
  530.  
  531. *      Title and header information
  532. *      - entered as a series of comments.
  533. .LIB    DEFAULT.LIB  ;   Logic primitive library files loaded
  534. *                        using the .LIB directive.
  535. .INCLUDE  DEFAULT.MAC ;  Macro library file loaded using the
  536. *                        .INCLUDE directive.
  537. *  Other macro definitions next.
  538. .MACRO    ............
  539.           ............
  540. .ENDM
  541. * Clock and logic function statements next.
  542. ...........................
  543. .TIME .............
  544. .PLOT or .PRINT statements.
  545. .END
  546. 5.4  Logic primitive libraries
  547.  
  548. Access to a library  of  primitive  logic  element  models  is  available  in 
  549. LSYSTEM.   To load a library, the statement
  550.  
  551.      .LIB   library_name
  552.  
  553. is entered near the beginning of the LSYSTEM network description  file.    At 
  554. least one model library must be loaded for LSYSTEM to function.   Please note 
  555. a primitive library must be loaded before any models in the library are used.  
  556. Only one library can be loaded per .LIB  command.    However,  as  many  .LIB 
  557. statements may be specified as required, for example:-
  558.  
  559.      .LIB default.LIB    ; load the SHAREWARE default model library.
  560.      .LIB gates.LIB      ; only supplied to registered users.
  561.      .LIB memory.LIB     ; again only supplied to registered users.
  562.  
  563.  
  564. 5.4.1     Using primitives
  565.  
  566. All primitive model definitions have the same structure, although some of the 
  567. information is redundant, depending on  the  primitive  type.    Three  basic 
  568. types of primitive model currently exist, they are
  569.  
  570.      - Combinational logic elements.
  571.      - Clocked sequential logic elements.
  572.      - memory elements.
  573.  
  574. Their  use  is  strictly  controlled  by,  for  example,  nodal  positioning, 
  575. triggering edges, and asynchronous input polarities.   Primitive  models  are 
  576. based on a look-up table.   Inputs specified in  the  model  definition  form 
  577. part of the look-up table index.   Hence, it is important that input nodes be 
  578. used in the correct order.   The structure of a  primitive  library  file  is 
  579. described in detail in Appendix B.   Information is  also  provided  to  help 
  580. LSYSTEM users construct their own primitive libraries.
  581.  
  582. 5.4.2     Combinational primitives
  583.  
  584. Combinational model primitives have one type of input, this is one  or  more, 
  585. non-clocked, logic inputs.  A primitive's outputs have a direct  relationship 
  586. to to these inputs since  the  model  is  purely  a  combinational  function.   
  587. Information specifying a primitive ALWAYS  has the following sequence:-
  588.  
  589.    - Input nodes, in the order given in the primitive definition.
  590.    - Output nodes, again in the order given in the primitive definition.
  591.    - The model name.
  592.  
  593. Hence, a functional element description for a primitive type called NAME  has 
  594. the format:-
  595.  
  596.    Element IN1 IN2 IN3 IN4 .... OUT1 OUT2 OUT3........ NAME
  597.       .
  598.       ........... Reference Element name to identify the logic component.
  599.  
  600. where each item in the list is separated by one or more spaces.
  601.  
  602. 5.4.3     Sequential primitives
  603.  
  604. Sequential primitives are a little  more  complex  than  combinational  ones.   
  605. Using them  is  very  advantageous  though,  since  it  allows  a  degree  of 
  606. FUNCTIONAL SIMULATION, which simplifies and  speeds  the  simulation  process 
  607. enormously.   When modelling a complex digital system, it is often sufficient 
  608. to just use a functional box to represent an element or  a  sub-unit  of  the 
  609. digital network, for example a D-TYPE flip flop, or an 8bit up/down  counter, 
  610. instead of having to code the entire logic system as gate level primitives.
  611.  
  612. The maximum internal state bits for a sequential primitive is 8, yielding 256 
  613. maximum internal states.   This is quite sufficient  for  most  purposes  and 
  614. restricts look-up tables to a moderate size ( a practical  consideration  due 
  615. to the DOS 640k memory limit).
  616.  
  617. Sequential primitives have FOUR types of input, these must  be  specified  in 
  618. the following order:-
  619.  
  620.     - Clock input node.
  621.     - Combinational input nodes, these DO NOT effect the internal state,
  622.       for example an OUTPUT ENABLE which switches a logic element into
  623.       tri state output mode.
  624.     - Asynchronous ( active low ) input nodes, for example CLEAR and PRESET
  625.       on a flip flop.
  626.     - Synchronous clocked ( rising edge triggered ) input nodes, for example
  627.       J and K on a flip flop.
  628.  
  629. The input node names are then followed by the output node list,  and  finally 
  630. the name of the logic primitive.   Hence. for example a 4 bit  counter  would 
  631. be described as:-
  632.  
  633.  
  634.      IC1 CLK OE CLEAR LOAD A B C D Qa Qb Qc Qd TC  4CountLoad
  635.  
  636. 5.4.4     RAM  primitives
  637.  
  638.           INFORMATION ONLY PROVIDED TO REGISTERED LSYSTEM USERS         
  639.  
  640.  
  641. 5.4.5     ROM primitives
  642.  
  643.           INFORMATION ONLY PROVIDED TO REGISTERED LSYSTEM USERS
  644.  
  645. 5.4.6     Default primitive library list.
  646.  
  647. 1.  EL IN1 IN2 OUT AND2 (DELAY=9 LOW=50 HIGH=40)
  648. 2.  EL IN1 IN2 OUT OR2 (DELAY=9 LOW=50 HIGH=40)
  649. 3.  EL IN OUT RES (DELAY=1 STRENGTH=10)
  650. 4.  EL IN OUT INV (DELAY=9 LOW=50 HIGH=40)
  651. 5.  EL CLK CLR PR J K Q NQ JKFF_CP_PE (RISE=9 FALL=15 LOW=50 HIGH=40)
  652. 6.  EL CLK CLR PR D Q NQ DFF_CP_PE (RISE=9 FALL=15 LOW=50 HIGH=40)
  653. 7.  EL IN1 IN2 IN3 IN4 OUT NAND4 (DELAY=9 LOW=50 HIGH=40)
  654. 8.  EL OE IN OUT TBUF (RISE=13 FALL=17 LOW=50 HIGH=40)
  655. 9.  EL I1 I2 I3 I4 I5 OUT AND5 (DELAY=9 LOW=50 HIGH=40)
  656.  
  657.     THE DEFAULT LIBRARY PROVIDED TO REGISTERED LSYSTEM USERS
  658.     CONSISTS OF 65 PRIMITIVES ---- SEPARATE GATE, FLIP FLOP,
  659.     OPEN CIRCUIT COMPONENT AND TRI STATE DEVICE LIBRARIES ARE
  660.     ALSO INCLUDED ON THE LSYSTEM PRODUCTION MASTER DISKS.
  661.  
  662. 5.5  The include file command - .INCLUDE
  663.  
  664. Include files are standard text files that are opened  and  read  by  LSYSTEM 
  665. compiler into the main network description file as it is being compiled.   As 
  666. many files as required can be defined for inclusion, although  only  ONE  per 
  667. .INCLUDE directive.   Include files can be nested to 20 levels deep, i.e., an 
  668. include file can call another include file which  can  call  another  include 
  669. file ...... up to 20 levels.
  670.  
  671. The syntax for the include command is:-
  672.  
  673.               .INCLUDE FILE_1.EXT
  674.               .INCLUDE FILE_2.EXT
  675.  
  676. The main use for this directive is for loading previously defined MACROS.   A 
  677. file containing some useful macros. prepared for direct  inclusion  into  any 
  678. network description, has been included on the LSYSTEM disks.   The macro file 
  679. is called DEFAULT.MAC.
  680.  
  681.  
  682.  
  683.